<template>
     <el-button type="info" plain @click="separate">分配</el-button>
     <el-table :data="tableData" height="500" border style="width: 100%">
    <el-table-column label="序号" width="120">
      <template v-slot="scope">
        {{ scope.$index + 1 }}
      </template>
    </el-table-column>
    <el-table-column prop="Unum" label="电话" width="120">
    </el-table-column>
    <el-table-column prop="Uprofessional" label="职称" width="120">
    </el-table-column>
    <el-table-column prop="Upopulation" label="家庭人口" width="120">
    </el-table-column>
    <el-table-column prop="Udepartment" label="部门" width="120">
    </el-table-column>
    <el-table-column prop="Housing_sco" label="住房分数" width="120">
    </el-table-column>
    <el-table-column prop="Urequire_hs_ar" label="要求住房面积" width="120">
    </el-table-column>
  </el-table>
</template>
<script>

export default{
        data() {
    return {
      tableData: [],
    };
   },
     mounted() {
    this.$http
      .get("api/auth/findsmsg")
      .then((response) => (this.tableData = response.data));
  },
   methods: {
       separate(){
           this.$http
        .post("api/auth/separte")
        .then((response) => (this.tableData));
       }
   }
}
</script>
